/* eslint-disable @typescript-eslint/explicit-module-boundary-types */
import { HttpSrv } from 'lfun-bg-comp';

export interface Leader {
  id(id: any): unknown;
  school_id: any;
  institution_id: any;
  planning_school_id: any;
  leader_name: string;
  position: string;
  status: string;
  start_date: string;
  end_date: string;
  job_content: string;
  job_responsibility: string;
}

// 删除
export const deleteLeader = leader_info_id =>
  HttpSrv().delete(`/school/v1/leaderinfo/?leader_info_id=${leader_info_id}`);
// 新增
export const createLeader = (params: Leader) => HttpSrv().post('/school/v1/leaderinfo/', params);
// 修改
export const updateLeader = (params: Leader) => HttpSrv().put('/school/v1/leaderinfo/', params);
// 分页查询
export const searchLeader = (planning_school_id: any, page: any, per_page: any) =>
  HttpSrv().get('/school/v1/leaderinfo/page', { params: { planning_school_id, page, per_page } });
